package com.kate.mall.common.constants;

/**
 * @Description: 用一句话描述
 * @Auther: 新梦想*陈超
 * @Date: 2021/10/25 16:36
 *
 * public  final int  code  =  401;
 * public final int msg = "请先登录";
 */

public enum WxResponseCode {
    AUTH_INVALID_ACCOUNT(700, "非法账号"),
    AUTH_CAPTCHA_UNSUPPORT(701, "验证码支持"),
    AUTH_CAPTCHA_FREQUENCY(702, "获取验证码过频"),
    AUTH_CAPTCHA_UNMATCH(703, "验证码不匹配"),
    AUTH_NAME_REGISTERED(704, "名字已注册"),
    AUTH_MOBILE_REGISTERED(705, "手机号已被注册"),
    AUTH_MOBILE_UNREGISTERED(706, "手机号未被注册"),
    AUTH_INVALID_MOBILE(707, "非法手机号"),
    AUTH_OPENID_UNACCESS(708, "订单不能支付"),
    AUTH_OPENID_BINDED(709, "openId绑定失败"),
    AUTH_FORBIDDEN(403, "没有相关权限"),
    AUTH_VALIDATE_FAILED(404, "参数检验失败"),
    AUTH_UNAUTHORIZED(401, "暂未登录或token已经过期"),

    GOODS_UNSHELVE(710, "商品下架"),
    GOODS_NO_STOCK(711, "售罄"),
    GOODS_UNKNOWN(712, "未知商品"),
    GOODS_INVALID(713, "商品非法"),

    ORDER_UNKNOWN(720, "未知订单"),
    ORDER_INVALID(721,"非法订单"),
    ORDER_CHECKOUT_FAIL(722,""),
    ORDER_CANCEL_FAIL (723,"订单取消失败"),
    ORDER_PAY_FAIL (724,"订单支付失败"),
    //订单当前状态下不支持用户的操作，例如商品未发货状态用户执行确认收货是不可能的。
    ORDER_INVALID_OPERATION(725,"订单非法操作"),
    ORDER_COMMENTED(726,"订单重复评论"),
    ORDER_COMMENT_EXPIRED(727,"订单评论过期"),


    GROUPON_EXPIRED(730,"团购过期"),
    COUPON_EXCEED_LIMIT(740,"团购超限量"),
    COUPON_RECEIVE_FAIL(741,"团购接收失败"),
    COUPON_CODE_INVALID(742,"团购码非法");

    private int code;
    private String msg;

    WxResponseCode(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}